<!--
 * @Author: your name
 * @Date: 2022-02-24 15:09:30
 * @LastEditTime: 2022-02-24 15:23:59
 * @LastEditors: Please set LastEditors
 * @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE"
 * @FilePath: \briup-study\JS\1-js.html
-->
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script>
        /* 代码顺序 */
        console.log(a);
        var a=1;
        var a="hello " ;
        console.log(a);
        /* 浏览器顺序 */
            var a;
            console.log(a)
            a=1
            console.log(a)

            /* var的特点：1、使用var声明的变量存在变量提升；2、重复声明不会报错 3、全局变量*/

            /* 判断数据类型用typeof */
            var b=2
            console.log(typeof(b))
            var c="hello"
            console.log(typeof(c))
    </script>
</head>
<body>
    
</body>
</html>